/**
 * @author Tobias Boehm
 *
 * 07.06.2011
 */
package org.anddev.andengine.extension.tbsengine.message.client.preparematch;

import java.io.DataInputStream;
import java.io.DataOutputStream;
import java.io.IOException;
import java.util.UUID;

import org.anddev.andengine.extension.tbsengine.message.ICopyable;
import org.anddev.andengine.extension.tbsengine.message.client.AbsClientMatchMessage;

/**
 * This client message should be used by the match creator to start a match.
 * 
 * @author Tobias Boehm
 *
 */
public class ClientStartMatchRequestMessage extends AbsClientMatchMessage implements ICopyable<ClientStartMatchRequestMessage> {

	/* (non-Javadoc)
	 * @see org.anddev.andengine.extension.multiplayer.protocol.adt.message.IMessage#getFlag()
	 */
	@Override
	public short getFlag() {
		
		return FLAG_CLIENT_START_MATCH_REQUEST;
	}

	/* (non-Javadoc)
	 * @see org.anddev.andengine.extension.tbsengine.message.client.AbsClientMatchMessage#onReadTransmissionClientMatchData(java.io.DataInputStream)
	 */
	@Override
	protected void onReadTransmissionClientMatchData(
			DataInputStream pDataInputStream) throws IOException {
		// TODO Auto-generated method stub

	}

	/* (non-Javadoc)
	 * @see org.anddev.andengine.extension.tbsengine.message.client.AbsClientMatchMessage#onWriteTransmissionClientMatchData(java.io.DataOutputStream)
	 */
	@Override
	protected void onWriteTransmissionClientMatchData(
			DataOutputStream pDataOutputStream) throws IOException {
		// TODO Auto-generated method stub

	}

	public void setMatchID(final UUID pMatchID) {
		
		this.mMatchID = pMatchID;
	}
	
	@Override
	public ClientStartMatchRequestMessage copy() {
		
		final ClientStartMatchRequestMessage copy = new ClientStartMatchRequestMessage();
		
		copy.mMatchID = this.mMatchID;
		copy.mPlayerID = this.mPlayerID;
		
		return copy;
	}


}
